<%@ page contentType="text/html;charset=GBK" %>
<%@ page import="java.util.*" %>
<%@ page import="com.ionglobal.db.*" %>
<%@ page import="com.ionglobal.lib.*" %>
<%@ page import="com.ionglobal.misc.*" %>

<%@ include file="../init_include.jsp" %>
<%
	Sysop sysop=(Sysop)session.getAttribute("sysop");
	if ( sysop==null)
	{
		dbi.closeAll();
		return;
	}

	String sql="";
	String userStr=dbi.fixSql(request.getParameter("user"));
	String moduleStr=dbi.fixSql(request.getParameter("module"));

	out.println(userStr+" "+moduleStr);

		//insert into cms_role(name,permission) values('kkk','01010101');
		sql ="insert into sysop_module(userid,moduleid,isallow) values(";
		sql+=userStr+","+moduleStr+",1)";
		Sysop.insertModule(dbi,sql);
		
		response.sendRedirect("userCommission.jsp?userid="+request.getParameter("userid"));
%>	
<%@ include file="../init_free.jsp" %>